package com.zimmur.app.mocolink.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.zimmur.app.mocolink.dao.GroupStyleMapper;
import com.zimmur.app.mocolink.domain.model.GroupStyle;
import com.zimmur.app.mocolink.domain.vo.GroupStyleVo;
import com.zimmur.app.mocolink.service.IGroupStyleService;

@Service
public class GroupStyleServiceImpl implements IGroupStyleService {

	@Autowired
	private GroupStyleMapper groupStyleMapper;

	@Override
	public List<GroupStyleVo> getAllStyle() {
		return groupStyleMapper.selectAllStyle();
	}

	@Override
	public GroupStyle selectById(Integer styleId) {
		return groupStyleMapper.selectByPrimaryKey(styleId);
	}

	@Override
	public int update(GroupStyle groupStyle) {
		return groupStyleMapper.updateByPrimaryKeySelective(groupStyle);
	}

	@Override
	public int add(GroupStyle groupStyle) {
		return groupStyleMapper.insertSelective(groupStyle);
	}

	@Override
	public int delete(Integer styleId) {
		return groupStyleMapper.deleteByPrimaryKey(styleId);
	}

	
}
